package com.btex.app.tools;

import android.util.Log;

public class LogUtil {
	private static boolean debug = true;
	public static void i(String TAG ,String message) {
		if (debug) 
			Log.i(TAG, message);
	}
	public static void v(String TAG ,String message) {
		if (debug) 
			Log.v(TAG, message);
	}
	public static void d(String TAG ,String message) {
		if (debug) 
			Log.d(TAG, message);
	}
	public static void w(String TAG ,String message) {
		if (debug) 
			Log.w(TAG, message);
	}
	public static void e(String TAG ,String message) {
		if (debug) 
			Log.e(TAG, message);
	}
	public static void i(String message) {
		if (debug)
			Log.i(getCurrentClassName(), message);
	}
	public static void v(String message) {
		if (debug)
			Log.v(getCurrentClassName(), message);
	}
	public static void d(String message) {
		if (debug)
			Log.d(getCurrentClassName(), message);
	}
	public static void w(String message) {
		if (debug)
			Log.w(getCurrentClassName(), message);
	}
	public static void e(String message) {
		if (debug)
			Log.e(getCurrentClassName(), message);
	}

	public static String getCurrentClassName() {
		int level = 1;
		StackTraceElement[] stacks = new Throwable().getStackTrace();
		String className = stacks[level].getClassName();
		return className;
	}
	
}